package com.liming.user.service.impl;

import com.liming.common.pojo.vo.coupon.mini.MiniProductUserCouponVO;
import com.liming.common.util.BeanUtils;
import com.liming.coupon.client.CouponUserClient;
import com.liming.user.service.CouponService;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author liming
 * @date 2025/3/22
 */
@Slf4j
@Service
@AllArgsConstructor
public class CouponServiceImpl implements CouponService {

    private final CouponUserClient couponUserClient;

    @Override
    public List<MiniProductUserCouponVO> couponDetailList(List<Long> couponIds) {
        return BeanUtils.toBean(couponUserClient.couponDetailList(couponIds), MiniProductUserCouponVO.class);
    }
}
